<?php

class Model_AppAuthAdapter extends Zend_Auth_Adapter_DbTable
{
    public function __construct()
    {
        $dbAuthAdapterConf = Zend_Registry::get('config')
                                ->database
                                ->authAdapter;
        parent::__construct(
                Zend_Registry::get('db'),
                $dbAuthAdapterConf->tableName,
                $dbAuthAdapterConf->identityColumn,
                $dbAuthAdapterConf->credentialColumn,
                'SHA1(?) AND has_confirmed_email = 1'
                );
    }
}
